<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>

    <script src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.8.0.js">
    </script>
</head>
<body>
    <form action="/api/user/login" method="post">
        <p>Username: <input type="text" name="username" /></p>
        <p>Password: <input type="text" name="password" /></p>
        <input type="submit" value="Submit" />
    </form>

    <div id="show"></div>
<button onclick="sumbit()">test</button>

    <form action="/api/user_login/login" method="post">
        <p>Username: <input type="text" name="username" /></p>
        <p>Password: <input type="text" name="password" /></p>
        <input type="submit" value="Submit" />
    </form>
<script type="text/javascript">
    function sumbit() {

        var post_body = "username=testusername&password=testpassword";

        $.post("/api/user/login",
                {
                    username:'testusername',
                    password:'testpassword'
                },
                function(result){
            $("div#show").html(result);
        });
    }
</script>
</body>
</html>